Vitamin D is a genus for a group of fat-soluble secosteroids responsible for enhancing intestinal absorption of minerals such as iron, magnesium, phosphate, calcium, and zinc. In humans, the most important compounds in this group are vitamin D2 (ergocalciferol) and vitamin D3 (also known as cholecalciferol). The synthesis of vitamin D in the skin is the main source of the vitamin. Dermal synthesis of vitamin D from cholesterol depends on sun exposure, specifically UVB radiation. Ergocalciferol and cholecalciferol can be ingested from diet and from supplements, since few foods contain vitamin D.
Magnesium is an important mineral that all cells in the human body need. Nearly half of the magnesium stored in the body is found in the body's organs and tissues, and the other half is found in our bones where it is found in combination with phosphorus and calcium. The body requires magnesium to carry out various biochemical functions such as enzyme activity. Magnesium deficiency can lead to a myriad of health conditions.